package FourHomeworkDesign.Flyweight;

/**
 * @author 北巷_东坡
 * @date 2022/11/13 18:46
 * @computer 10741
 */
public class Word206 {
    private String str;
    private String font = "Arial";//默认字体
    private String color = "Black";//默认颜色

    public Word206(String str) {
        this.str = str;
    }

    public void setColor(Color206 color) {
        this.color = color.getColor();
    }

    public void setFont(Font206 font) {
        this.font = font.getFont();
    }

    @Override
    public String toString() {
        return "Word [str=" + str + ", font=" + font + ", color=" + color + "]";
    }
}
